package com.shop.shoporder.mapper;

import com.shop.shoporder.entity.GoodsCollect;
import com.shop.shoporder.entity.GoodsCollectInfo;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface GoodsCollectMapper {
    int deleteByPrimaryKey(int gcId);

    int insert(GoodsCollect record);

    int insertSelective(GoodsCollect record);

    GoodsCollect selectByPrimaryKey(int gcId);

    int updateByPrimaryKeySelective(GoodsCollect record);

    int updateByPrimaryKey(GoodsCollect record);

    List<GoodsCollect> selectList();

    /**
     * 查询用户收藏的商品
     * @param userNoId
     * @return
     */
    List<GoodsCollectInfo> selectGoodsCollectList(int userNoId);

    /**
     * 查询某个商品收藏
     * @param goodsCollect
     * @return
     */
    GoodsCollect queryCollectGoodsByUserNoId(GoodsCollect goodsCollect);

}